<extend name="_layout/main" />
<block name="content">
	<div class="page-content">
		<div class="page-breadcrumbs">
			<ul class="breadcrumb">
				<li>
					<i class="fa fa-home"></i>
					<a href="{:U('dashboard/index')}">系统首页</a>
				</li>
				<li class="active">系统账目</li>
			</ul>
		</div>

		<div class="page-body">
			<div class="row">
				<div class="col-lg-12 col-sm-12 col-xs-12">
					<div class="widget">
						<div class="widget-header bordered-left bordered-darkorange">
							<span class="widget-caption">搜索</span>
						</div>
						<div class="widget-body bordered-left bordered-warning">
							<form class="form-inline" role="form">
								
								<div class="form-group">
									<input type="text" class="form-control" name="mobile" placeholder="会员手机" value="{$Think.request.mobile}">
								</div>
								<div class="form-group">
									<input type="text" class="form-control" name="nickname" placeholder="用户名" value="{$Think.request.nickname}">
								</div>
								<div class="form-group">
									<div class="input-group">
										<input type="text" class="form-control" name="date_range" id="date_range" placeholder="订单时间" value="{$Think.request.date_range}">
									</div>
								</div>	
								<button type="submit" class="btn btn-default">搜索</button>
							</form>
						</div>
					</div>
				</div>
			</div>
			<div class="row">
				<div class="col-xs-12 col-md-12">
					<div class="widget">

						<table class="table table-hover" id="searchable">
							<thead class=" ">
								<tr role="row">
									<th class="text-center">ID</th>
									<th class="text-center">用户名</th>
                                    <th class="text-center">手机</th>
									<th class="text-center">身份</th>
									<th class="text-center">类型</th>
									<th class="text-center">金额</th>
									<th class="text-center">时间</th>
									<th>备注</th>
								</tr>
							</thead>

							<tbody>
								<notempty name="result">
									<volist name="result" id="val" mod="2">
										<tr>
											<th class="text-center">{$val.id}</th>
											<td  class="text-center">{$val.nickname}</td>
                                            <td  class="text-center">{$val.mobile}</td>
											<td  class="text-center">{:userIdentity($val['identity'])}</td>
											<td  class="text-center">{:userAccountType($val['type_id'])}</td>
											<td  class="text-center"><eq name="val['source']" value="0">-<else />+</eq> {$val.amount}</td>
											<td  class="text-center">{$val.created_at|format_time}</td>
											<td >{$val.remark}</td>
										</tr>
									</volist>
									<else/>
									<tr>
										<td colspan="4" align="center">没有数据</td>
									</tr>
								</notempty>
							</tbody>
						</table>
						<div class="row DTTTFooter">
							<div class="col-sm-6">
								<div class="dataTables_info" id="simpledatatable_info" role="status" aria-live="polite">

								</div>
							</div>
							<div class="col-sm-6">
								<div class="dataTables_paginate paging_bootstrap" id="simpledatatable_paginate">
									{$page}
								</div>
							</div>
						</div>
					</div>
				</div>
			</div>

		</div>
		<!-- /Page Body -->
	</div>
</block>
<block name="footer">
	<!--Bootstrap Date Range Picker-->
	<script src="__PUBLIC__/assets/js/datetime/moment.js"></script>
	<script src="__PUBLIC__/assets/js/datetime/zh-cn.js" type="text/javascript" charset="utf-8"></script>
	<script src="__PUBLIC__/assets/js/datetime/daterangepicker.js"></script>

	<script type="text/javascript">
		moment.lang('zh-cn');
		$('#date_range').daterangepicker({
			format: 'YYYY-MM-DD',
			locale: {
				applyLabel: '确定',
				cancelLabel: '取消',
				
			},
			
		});
	</script>
</block>